import { ecs } from "db://app-game/libs/ecs/ECS";
import {
  RoleLowerBodyAnimatorEnum,
  RoleUpperBodyAnimatorEnum,
} from "../Role.type";

/** 角色状态组件 */
@ecs.register("RoleControl")
export class RoleControlComp extends ecs.Comp {
  /** 当前状态 */
  currentLowerState: RoleLowerBodyAnimatorEnum = RoleLowerBodyAnimatorEnum.Idle;
  currentUpperState: RoleUpperBodyAnimatorEnum = RoleUpperBodyAnimatorEnum.Idle;

  /** 下半身动画权重 */
  lowerAnimationWeight = {
    [RoleLowerBodyAnimatorEnum.Idle]: 0,
    [RoleLowerBodyAnimatorEnum.Walk]: 0,
    [RoleLowerBodyAnimatorEnum.Run]: 0,
  };

  /** 上半身动画权重 */
  upperAnimationWeight = {
    [RoleUpperBodyAnimatorEnum.Idle]: 0,
    [RoleUpperBodyAnimatorEnum.Walk]: 0,
    [RoleUpperBodyAnimatorEnum.Run]: 0,
  };
  reset(entity: ecs.Entity): void {}
}
